import request from "@/utils/request";

// 回收登记列表
export function listTable(query) {
  return request({
    url: "/system/skesItem/list",
    method: "get",
    params: query,
  });
}

// 删除商品
export function delItem(itemIds) {
  return request({
    url: '/system/skesItem/' + itemIds,
    method: 'delete'
  })
}
// 新增商品
export function addItem(data) {
  return request({
    url: '/system/skesItem/',
    method: 'post',
    data,
    "Content-Type": 'multipart/form-data'
  })
}
// 修改商品
export function updateItem(data) {
  return request({
    url: '/system/skesItem',
    method: 'put',
    data
  })
}
// 获取商品详细信息
export function getItem(id) {
  return request({
    url: '/system/skesItem/' + id,
    method: 'get'
  })
}
// 商品列表下拉框查询
export function optionSelect(query) {
  return request({
    url: '/system/skesItem/optionSelect',
    method: 'get',
    params: query,
  })
}

// 商品列表下拉框查询
export function uploadApi(data) {
  return request({
    url: '/system/skesItem/upload',
    method: 'post',
    data,
    "Content-Type": 'multipart/form-data'
  })
}

